package javabase.schoolwork.day5_24;

/**
 * @author fance
 * @date 2018/5/24 20:06
 */
public class TriAngle {
    private double base;
    private double height;

    public TriAngle() {
    }

    public TriAngle(double base, double height) {
        this.base = base;
        this.height = height;
    }

    public double getBase() {
        return base;
    }

    public void setBase(double base) {
        this.base = base;
    }

    public double getHeight() {
        return height;
    }

    public void setHeight(double height) {
        this.height = height;
    }

    @Override
    public String toString() {
        return "TriAngle{" +
                "base=" + base +
                ", height=" + height +
                '}';
    }
    public double calArea() {
        return base * height;
    }
}
